from ckeditor.widgets import CKEditorWidget
from django import forms

from main.models import ArticleModel




class ArticleForm(forms.ModelForm):
    class Meta:
        model = ArticleModel
        fields = ['title', 'content','tags','category']
        widgets = {
            'title': forms.TextInput(attrs={'class': 'form-control'}),
            # 'content': forms.Textarea(attrs={'class': 'form-control'}),
            'content':CKEditorWidget(attrs={'class': 'form-control'})
        }